﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace Bon.it.MasterData
{
    /// <summary>
    /// Interaktionslogik für ArticleDetails.xaml
    /// </summary>
    public partial class ArticleDetails : UserControl
    {
        public ArticleDetails()
        {
            InitializeComponent();
        }

        private void TextBox_TextChanged(object sender, TextChangedEventArgs e)
        {
            InputHandlers.DecimalTextChangedEventHandler(sender, null);
        }

        private void TextBox_Pasting(object sender, DataObjectPastingEventArgs e)
        {
            InputHandlers.DecimalPastingHandler(sender,e);
        }

        private void EanPasted(object sender, DataObjectPastingEventArgs e)
        {
            InputHandlers.NumericPastingHandler(sender,e);
        }

        private void EANChanged(object sender, TextChangedEventArgs e)
        {
            InputHandlers.NumericTextChangedEventHandler(sender,null);
        }

        private void EANPreviewTextInput(object sender, TextCompositionEventArgs e)
        {
            InputHandlers.NumericPreviewTextInputHandler(sender,e);
        }

        private void BestandPasting(object sender, DataObjectPastingEventArgs e)
        {
            InputHandlers.DecimalPastingHandler(sender, e);
        }

        private void BestandTextChanged(object sender, TextChangedEventArgs e)
        {
            InputHandlers.DecimalTextChangedEventHandler(sender, null);

        }
    }
}
